Signal Classification Method and Device, and Encoding and Decoding Methods and Devices

ABSTRACT

Embodiments of the present invention provide a signal classification method and device, and encoding and decoding methods and devices. The encoding method includes dividing a current frame into a low-frequency band signal and a high-frequency band signal, attenuating the high-frequency band signal or a to-be-encoded characteristic parameter of the high-frequency band signal according to an energy attenuation value of the low-frequency band signal, where the energy attenuation value indicates energy attenuation of the low-frequency band signal caused by encoding of the low-frequency band signal, and encoding the attenuated high-frequency band signal or the attenuated to-be-encoded characteristic parameter of the high-frequency band signal. The technical solutions according to the embodiments of the present invention can improve the effect of combining the low-frequency band signal and the high-frequency band signal at the decoder.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. patent application Ser. No.13/728,201, filed on Dec. 27, 2012, which is a continuation ofInternational Patent Application No. PCT/CN2011/081114, filed on Oct.21, 2011. The International Application claims priority to ChinesePatent Application No. 201110138461.1, filed on May 25, 2011. Theafore-mentioned patent applications are hereby incorporated herein byreference in their entireties.

TECHNICAL FIELD

The present invention relates to the field of speech and audiotechnologies, and in particular, to a signal classification method anddevice, and encoding and decoding methods and devices.

BACKGROUND

In audio and speech processing technologies, a bandwidth expansiontechnology already emerges, that is, a high-frequency band signal isencoded using a small number of bits so as to expand a frequency bandrange of a speech/audio signal. The bandwidth expansion technology hasdeveloped fast in recent years and has been commercially applied in someencoders and decoders.

The bandwidth expansion technology adopted currently is basically amulti-mode bandwidth expansion technology, where according to signalcharacteristics of a high-frequency band signal in an input signal, asignal class of the high-frequency band signal is determined, anddifferent encoding and decoding algorithms are adopted for differentsignal classes. According to signal characteristics of high-frequencyband signals, the high-frequency band signals are classified into fourclasses: a transient (Transient) class, a harmonic class (Harmonic), anoise (Noise) class and a normal (Normal) class. A specificclassification process includes dividing a high-frequency bandtime-domain signal of a certain frame into several sub-frames, obtaininga time-domain envelope of each sub-frame, and when energy of a certainsub-frame is greater than a certain number of times of energy of aprevious sub-frame and the energy of the sub-frame is greater than acertain number of times of average energy of all sub-frames in the wholeframe, determining that the high-frequency band signal of the frame isof the transient class. If the frame is not of the transient class,dividing a high-frequency band frequency-domain signal of the frame intoseveral sub-bands, obtaining a peak-to-average ratio of each sub-band,where the peak-to-average ratio is a ratio of peak energy or amplitudeof the sub-band to average energy or amplitude of the sub-band, and whenthe number of sub-bands having a peak-to-average ratio greater than athreshold is greater than a certain number, determining that thehigh-frequency band signal of the frame is of the harmonic class. Whenthe number of sub-bands having a peak-to-average ratio smaller than athreshold is greater than a certain number, determining that thehigh-frequency band signal of the frame is noise. Otherwise, determiningthat the high-frequency band signal of the frame is of the normal class.

The prior art has the following disadvantages.

In the prior art, during signal classification for a high-frequency bandsignal of a certain frame, only characteristics of the high-frequencyband signal of the frame are considered, which results in an inaccuratesignal classification result for the high-frequency band signal of theframe.

SUMMARY OF THE INVENTION

Embodiments of the present invention provide a signal classificationmethod and a signal classification device, which provide a more accuratesignal classification result.

In view of this, the embodiments of the present invention provide thefollowing.

A signal classification method includes dividing a current frame into alow-frequency band signal and a high-frequency band signal, determining,according to a value requirement of a preset encoding/decodingcharacteristic parameter corresponding to a signal class, whether anencoding/decoding characteristic parameter of the current framecorresponding to the signal class meets the value requirement of theencoding/decoding characteristic parameter, and determining a signalclass of the high-frequency band signal of the current frame accordingto a determining result.

A signal classification device includes a division unit, configured todivide a current frame into a low-frequency band signal and ahigh-frequency band signal, a judgment unit, configured to determine,according to a value requirement of a preset encoding/decodingcharacteristic parameter corresponding to a signal class, whether anencoding/decoding characteristic parameter of the current framecorresponding to the signal class meets the value requirement of theencoding/decoding characteristic parameter, and a determination unit,configured to determine a signal class of the high-frequency band signalof the current frame according to a determining result.

An encoding method includes dividing a current frame into alow-frequency band signal and a high-frequency band signal, attenuatingthe high-frequency band signal or a to-be-encoded characteristicparameter of the high-frequency band signal according to an energyattenuation value of the low-frequency band signal, where the energyattenuation value indicates energy attenuation of the low-frequency bandsignal caused by encoding of the low-frequency band signal, and encodingthe attenuated high-frequency band signal or the attenuatedto-be-encoded characteristic parameter of the high-frequency bandsignal.

A decoding method includes decoding a bit stream to obtain ahigh-frequency band signal of a current frame or a characteristicparameter of the high-frequency band signal of the current frame, andattenuating the high-frequency band signal or the characteristicparameter of the high-frequency band signal according to an energyattenuation value of a low-frequency band signal of the current frame,where the energy attenuation value indicates energy attenuation of thelow-frequency band signal caused by encoding of the low-frequency bandsignal.

An encoding device includes a division unit, configured to divide acurrent frame into a low-frequency band signal and a high-frequency bandsignal, a correction unit, configured to attenuate the high-frequencyband signal or a to-be-encoded characteristic parameter of thehigh-frequency band signal according to an energy attenuation value ofthe low-frequency band signal, where the energy attenuation valueindicates energy attenuation of the low-frequency band signal caused byencoding of the low-frequency band signal of the current frame, and anencoding unit, configured to encode the attenuated high-frequency bandsignal or the attenuated to-be-encoded characteristic parameter of thehigh-frequency band signal.

A decoding device includes a decoding unit, configured to decode a bitstream to obtain a high-frequency band signal of a current frame or acharacteristic parameter of the high-frequency band signal of thecurrent frame, and a correction unit, configured to attenuate thehigh-frequency band signal or the characteristic parameter of thehigh-frequency band signal according to an energy attenuation value of alow-frequency band signal of the current frame, where the energyattenuation value indicates energy attenuation of the low-frequency bandsignal caused by encoding of the low-frequency band signal of thecurrent frame.

In an embodiment of the present invention, during signal classification,it is determined according to a value requirement of a presetencoding/decoding characteristic parameter corresponding to a signalclass, whether an encoding/decoding characteristic parameter of acurrent frame meets the value requirement of the encoding/decodingcharacteristic parameter, so as to determine whether a signal class of ahigh-frequency band signal of the current frame is the signal classcorresponding to the encoding/decoding characteristic parameter, and inthis way, encoding/decoding characteristics of different signal classesare taken into consideration during signal classification, therebymaking the signal classification for the high-frequency band signal ofthe current frame more accurate.

In another embodiment of the present invention, a high-frequency bandsignal or a to-be-encoded characteristic parameter of the high-frequencyband signal is attenuated according to an energy attenuation value of alow-frequency band signal of a current frame, and an attenuation resultis encoded and sent to a decoder, so that energy of the high-frequencyband signal obtained by the decoder by decoding is attenuatedaccordingly, thereby achieving a better effect after the high-frequencyband signal is combined with the low-frequency band signal.

BRIEF DESCRIPTION OF THE DRAWINGS

To illustrate the technical solutions according to the embodiments ofthe present invention more clearly, the accompanying drawings fordescribing the embodiments are introduced briefly in the following.Apparently, the accompanying drawings in the following description areonly some embodiments of the present invention, and persons of ordinaryskill in the art can derive other drawings from the accompanyingdrawings without creative efforts.

FIG. 1 is a flow chart of a signal classification method provided in anembodiment of the present invention;

FIG. 2A and FIG. 2B is a flow chart of a signal classification methodprovided in another embodiment of the present invention;

FIG. 3 is a structural diagram of a signal classification deviceprovided in an embodiment of the present invention;

FIG. 4 is a flow chart of an encoding method provided in an embodimentof the present invention;

FIG. 5 is a flow chart of another encoding method provided in anembodiment of the present invention;

FIG. 6 is a flow chart of a decoding method provided in an embodiment ofthe present invention;

FIG. 7 is a flow chart of another decoding method provided in anembodiment of the present invention;

FIG. 8 is a structural diagram of an encoding device provided in anembodiment of the present invention; and

FIG. 9 is a structural diagram of a decoding device provided in anembodiment of the present invention.

DETAILED DESCRIPTION OF ILLUSTRATIVE EMBODIMENTS

The following embodiments of the present invention takeencoding/decoding characteristics of different signal classes intoconsideration during signal classification, and to make the technicalsolutions according to the embodiments of the present invention clearer,characteristics of encoding/decoding algorithms for different signalclasses are described briefly in the following.

1. When the class of a high-frequency band signal of a current frame isa noise class, the encoding/decoding process of the high-frequency bandsignal of the current frame includes, during encoding, an encoder needsto obtain ratios of frequency-domain envelopes of sub-bands of thehigh-frequency band signal to frequency-domain envelopes ofcorresponding sub-bands of a low-frequency band signal, and send theratios to a decoder. In this manner, the encoder and the decoderpredetermine a mapping relationship between a certain sub-band of thehigh-frequency band signal and a certain sub-band of the low-frequencyband signal. Alternatively, the encoder searches, according to thefrequency-domain envelopes of the sub-bands of the low-frequency bandsignal, for a sub-band that is most correlated to a frequency-domainenvelope of a sub-band of the high-frequency band signal, and then sendsthe decoder a sub-band number (that is, a serial number of the foundsub-band of the low-frequency band signal), and a ratio of thefrequency-domain envelope of the sub-band of the high-frequency bandsignal to the frequency-domain envelope of the found sub-band of thelow-frequency band signal. During decoding, the decoder searches for asub-band of the low-frequency band signal corresponding to the sub-bandnumber, and determines a frequency-domain envelope of each sub-band ofthe high-frequency band signal according to the ratio sent by theencoder and the frequency-domain envelope of the sub-band of thelow-frequency band signal determined according to the sub-band number.The decoder directly uses an excitation spectrum of a specifiedfrequency range of the low frequency band as an excitation spectrum ofthe high frequency band, and in this way, a data frame of the noiseclass can be decoded successfully. It can be seen from the aboveanalysis that, because the encoding/decoding algorithm utilizes thecorrelation between the frequency-domain envelopes of the sub-bands ofthe high-frequency band signal and the frequency-domain envelopes of thecorresponding sub-bands of the low-frequency band signal when the classof the high-frequency band signal of the current frame is the noiseclass, it may be considered, during signal classification, that theclass of the high-frequency band signal for which the frequency-domainenvelope of the high-frequency band signal is strongly correlated to thefrequency-domain envelope of the low-frequency band signal may bedetermined as the noise class on the premise that the number ofsub-bands having a peak-to-average ratio smaller than a threshold isgreater than a certain number.

2. When the class of the high-frequency band signal of the current frameis a predicted class, the encoding/decoding process of thehigh-frequency band signal of the data frame includes, during encoding,the encoder first selects, from excitation spectrums of sub-bands of thelow-frequency band signal, a sub-band that is most correlated toexcitation spectrums of sub-bands of the high-frequency band signal,sends a serial number of the selected sub-band to the decoder, and atthe same time, sends frequency-domain envelopes of the sub-bands of thehigh-frequency band signal to the decoder. The decoder determines,according to the received frequency-domain envelopes of the sub-bands ofthe high-frequency band signal, a frequency-domain envelope of the wholehigh-frequency band signal, and predicts excitation spectrums of thesub-bands of the high-frequency band signal from the low-frequency bandsignal according to the received sub-band serial number, so as todetermine an excitation spectrum of the whole high-frequency bandsignal. It can be seen from the above analysis that, because theencoding/decoding algorithm utilizes the correlation between theexcitation spectrum of the high-frequency band signal and the excitationspectrum of the low-frequency band signal when the class of thehigh-frequency band signal of the current frame is the predicted class,it may be considered, during signal classification, that the class ofthe high-frequency band signal for which the excitation spectrum of thehigh-frequency band signal is strongly correlated to the excitationspectrum of the low-frequency band signal may be determined as thepredicted class.

3. When the class of the high-frequency band signal of the current frameis a transient class, the processing manner for the excitation spectrumis similar to the noise class, so the details are not described hereinagain. The difference lies in that, the encoder needs to send bothtime-domain envelopes of sub-frames and frequency-domain envelopes ofsub-bands of the high-frequency band signal to the decoder. The decoderrecovers the high-frequency band signal according to the aboveinformation sent by the encoder.

4. When the class of the high-frequency band signal of the current frameis a harmonic class, the processing manner for the excitation spectrumis basically similar to the noise class, so the details will not bedescribed herein again. The difference lies in that, the encoder needsto send frequency-domain envelopes of sub-bands of the high-frequencyband signal to the decoder. The decoder recovers the high-frequency bandsignal according to the above information sent by the encoder.

5. When the class of the high-frequency band signal of the current frameis a normal class, the processing manner for the excitation spectrum issimilar to that for the noise class, so the details are not describedherein again. The difference lies in that, the encoder needs to sendfrequency-domain envelopes of sub-bands of the high-frequency bandsignal to the decoder. The decoder recovers the high-frequency bandsignal according to the above information sent by the encoder.

Referring to FIG. 1, an embodiment of the present invention provides asignal classification method, where the method specifically includes thefollowing.

101: Divide a current frame into a low-frequency band signal and ahigh-frequency band signal.

The embodiment of the present invention is implemented by an encoder.

Specifically, the low-frequency band signal and the high-frequency bandsignal are relative concepts, and generally, a current frame is dividedby a quadrature minor filter (Quadrature Minor Filter, QMF from thecenter frequency of the current frame into a low-frequency band signaland a high-frequency band signal. However, the present invention is notlimited thereto, and the current frame may also be divided from otherfrequencies into a low-frequency band signal and a high-frequency bandsignal in other processing manners.

102: Determine, according to a value requirement of a presetencoding/decoding characteristic parameter corresponding to a signalclass, whether an encoding/decoding characteristic parameter of thecurrent frame corresponding to the signal class meets the valuerequirement of the encoding/decoding characteristic parameter. Thesignal class corresponding to the encoding/decoding characteristicparameter is a signal class having encoding/decoding characteristicsrepresented by the encoding/decoding characteristic parameter.

That is, it is determined, according to the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thesignal class, whether a value of the encoding/decoding characteristicparameter of the current frame corresponding to the signal class meetsthe value requirement of the encoding/decoding characteristic parameter.

The preset encoding/decoding characteristic parameter corresponding tothe signal class includes at least one of: an encoding/decodingcharacteristic parameter corresponding to a noise class, anencoding/decoding characteristic parameter corresponding to a predictedclass, and an encoding/decoding characteristic parameter correspondingto a harmonic class.

The encoding/decoding characteristic parameter corresponding to thenoise class is one of: a correlation parameter between an amplitude of alow-frequency band frequency-domain signal and an amplitude of ahigh-frequency band frequency-domain signal, and a correlation parameterbetween energy of the low-frequency band frequency-domain signal andenergy of the high-frequency band frequency-domain signal, where, theencoding/decoding characteristic parameter corresponding to the noiseclass is not limited to the correlation parameter between the amplitude(or energy) of the low-frequency band frequency-domain signal and theamplitude (or energy) of the high-frequency band frequency-domainsignal, but may be correlation parameters between other feature valuesof the low-frequency band frequency-domain signal and other featurevalues of the high-frequency band frequency-domain signal, which doesnot influence the implementation of the present invention.

When the encoding/decoding characteristic parameter corresponding to thenoise class is the correlation parameter between the amplitude of thelow-frequency band frequency-domain signal and the amplitude of thehigh-frequency band frequency-domain signal, this step is, specifically,determining whether the correlation parameter between the amplitude ofthe low-frequency band frequency-domain signal and the amplitude of thehigh-frequency band frequency-domain signal of the current frame meets avalue requirement of a preset correlation parameter between theamplitude of the low-frequency band frequency-domain signal and theamplitude of the high-frequency band frequency-domain signal. When theencoding/decoding characteristic parameter corresponding to the noiseclass is the correlation parameter between the energy of thelow-frequency band frequency-domain signal and the energy of thehigh-frequency band frequency-domain signal, this step is, specifically,determining whether the correlation parameter between the energy of thelow-frequency band frequency-domain signal and the energy of thehigh-frequency band frequency-domain signal of the current frame meets avalue requirement of a preset correlation parameter between the energyof the low-frequency band frequency-domain signal and the energy of thehigh-frequency band frequency-domain signal.

The value requirement of the preset encoding/decoding characteristicparameter corresponding to the noise class may specifically be greaterthan a certain threshold, or within a value range. The value requirementof the correlation parameter between the amplitude of the low-frequencyband frequency-domain signal and the amplitude of the high-frequencyband frequency-domain signal and the value requirement of thecorrelation parameter between the energy of the low-frequency bandfrequency-domain signal and the energy of the high-frequency bandfrequency-domain signal may be the same or different.

The encoding/decoding characteristic parameter corresponding to thepredicted class is one of: a correlation parameter between afrequency-domain coefficient of the low-frequency band signal and afrequency-domain coefficient of the high-frequency band signal, acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band signal and an absolute value ofthe frequency-domain coefficient of the high-frequency band signal, acorrelation parameter between a frequency-domain coefficient of a lowfrequency excitation spectrum and a frequency-domain coefficient of ahigh frequency excitation spectrum, a correlation parameter between anabsolute value of the frequency-domain coefficient of the low frequencyexcitation spectrum and an absolute value of the frequency-domaincoefficient of the high frequency excitation spectrum. Theencoding/decoding characteristic parameter corresponding to thepredicted class is not limited to the above correlation parameters, butmay be correlation parameters between other feature values of thelow-frequency band signal and other feature values of the high-frequencyband signal, or correlation parameters between other feature values ofthe low-frequency band excitation spectrum and other feature values ofthe high frequency excitation spectrum, which does not influence theimplementation of the present invention.

When the encoding/decoding characteristic parameter corresponding to thepredicted class is the correlation parameter between thefrequency-domain coefficient of the low-frequency band signal and thefrequency-domain coefficient of the high-frequency band signal, thisstep is, specifically, determining whether the correlation parameterbetween the frequency-domain coefficient of the low-frequency bandsignal and the frequency-domain coefficient of the high-frequency bandsignal of the current frame meets a value requirement of a presetcorrelation parameter between the frequency-domain coefficient of thelow-frequency band signal and the frequency-domain coefficient of thehigh-frequency band signal. When the encoding/decoding characteristicparameter corresponding to the predicted class is the correlationparameter between the absolute value of the frequency-domain coefficientof the low-frequency band signal and the absolute value of thefrequency-domain coefficient of the high-frequency band signal, thisstep is, specifically, determining whether the correlation parameterbetween the absolute value of the frequency-domain coefficient of thelow-frequency band signal and the absolute value of the frequency-domaincoefficient of the high-frequency band signal of the current frame meetsa value requirement of a preset correlation parameter between theabsolute value of the frequency-domain coefficient of the low-frequencyband signal and the absolute value of the frequency-domain coefficientof the high-frequency band signal. When the encoding/decodingcharacteristic parameter corresponding to the predicted class is thecorrelation parameter between the frequency-domain coefficient of thelow frequency excitation spectrum and the frequency-domain coefficientof the high frequency excitation spectrum, this step is, specifically,determining whether the correlation parameter between thefrequency-domain coefficient of the low frequency excitation spectrumand the frequency-domain coefficient of the high frequency excitationspectrum of the current frame meets a value requirement of a presetcorrelation parameter between the frequency-domain coefficient of thelow frequency excitation spectrum and the frequency-domain coefficientof the high frequency excitation spectrum. When the encoding/decodingcharacteristic parameter corresponding to the predicted class is thecorrelation parameter between the absolute value of the frequency-domaincoefficient of the low frequency excitation spectrum and the absolutevalue of the frequency-domain coefficient of the high-frequency bandexcitation spectrum, this step is, specifically, determining whether thecorrelation parameter between the absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum and theabsolute value of the frequency-domain coefficient of the high-frequencyband excitation spectrum meets a value requirement of a presetcorrelation parameter between the absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum and theabsolute value of the frequency-domain coefficient of the high-frequencyband excitation spectrum.

The value requirement of the preset encoding/decoding characteristicparameter corresponding to the predicted class may specifically begreater than a certain threshold, or within a value range. The valuerequirement of the correlation parameter between the frequency-domaincoefficient of the low-frequency band signal and the frequency-domaincoefficient of the high-frequency band signal, the value requirement ofthe correlation parameter between the absolute value of thefrequency-domain coefficient of the low-frequency band signal and theabsolute value of the frequency-domain coefficient of the high-frequencyband signal, the value requirement of the correlation parameter betweenthe frequency-domain coefficient of the low-frequency band excitationspectrum and the frequency-domain coefficient of the high-frequency bandexcitation spectrum, and the value requirement of the correlationparameter between the absolute value of the frequency-domain coefficientof the low-frequency band excitation spectrum and the absolute value ofthe frequency-domain coefficient of the high-frequency band excitationspectrum may be the same or different, which does not influence theimplementation of the present invention.

The encoding/decoding characteristic parameter corresponding to theharmonic class is one of: a correlation parameter between afrequency-domain coefficient of the low-frequency band signal and afrequency-domain coefficient of the high-frequency band signal, acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band signal and an absolute value ofthe frequency-domain coefficient of the high-frequency band signal, acorrelation parameter between a frequency-domain coefficient of alow-frequency band excitation spectrum and a frequency-domaincoefficient of a high-frequency band excitation spectrum, and acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum and anabsolute value of the frequency-domain coefficient of the high-frequencyband excitation spectrum, and the relevant description is the same asthat of the value requirement of the encoding/decoding characteristicparameter corresponding to the predicted class, so the details will notbe described herein again.

It should be noted that, the signal class in the presetencoding/decoding characteristic parameter corresponding to the signalclass is not limited to the above classes, but encoding/decodingcharacteristic parameters corresponding to other signal classes may alsobe preset, which does not influence the implementation of the presentinvention.

103: Determine a signal class of the high-frequency band signal of thecurrent frame according to a determining result.

In an implementation, when a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to the noiseclass meets the value requirement of the preset encoding/decodingcharacteristic parameter corresponding to the noise class, it isdetermined that the signal class of the high-frequency band signal ofthe current frame is the noise class. In an exemplary implementation,when the number of sub-bands having a peak-to-average ratio smaller thana second threshold is greater than a second predetermined number, and avalue of the encoding/decoding characteristic parameter of the currentframe corresponding to the noise class meets the value requirement ofthe preset encoding/decoding characteristic parameter corresponding tothe noise class, it is determined that the signal class of thehigh-frequency band signal of the current frame is the noise class.

In an implementation, if the preset encoding/decoding characteristicparameter corresponding to the signal class includes theencoding/decoding characteristic parameter corresponding to thepredicted class, or the encoding/decoding characteristic parametercorresponding to the harmonic class, when the encoding/decodingcharacteristic parameter of the current frame corresponding to thepredicted class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to thepredicted class, it is determined that the signal class of thehigh-frequency band signal of the current frame is the predicted class.Alternatively, when the encoding/decoding characteristic parameter ofthe current frame corresponding to the harmonic class meets a valuerequirement of a preset encoding/decoding characteristic parametercorresponding to the harmonic class, it is determined that the signalclass of the high-frequency band signal of the current frame is theharmonic class. In an exemplary implementation, when the number ofsub-bands having a peak-to-average ratio greater than a first thresholdis greater than a first predetermined number, and the encoding/decodingcharacteristic parameter of the current frame corresponding to theharmonic class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to the harmonicclass, it is determined that the signal class of the high-frequency bandsignal of the current frame is the harmonic class, or, when the numberof sub-bands having a peak-to-average ratio greater than the firstthreshold is not greater than the first predetermined number, and theencoding/decoding characteristic parameter of the current framecorresponding to the predicted class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thepredicted class, it is determined that the signal class of thehigh-frequency band signal of the current frame is the predicted class,or, alternatively, when the number of sub-bands having a peak-to-averageratio greater than the first threshold is not greater than the firstpredetermined number, the number of sub-bands having a peak-to-averageratio smaller than the second threshold is not greater than the secondpredetermined number, and the encoding/decoding characteristic parameterof the current frame corresponding to the predicted class meets thevalue requirement of the preset encoding/decoding characteristicparameter corresponding to the predicted class, it is determined thatthe signal class of the high-frequency band signal of the current frameis the predicted class.

In an implementation, if the preset encoding/decoding characteristicparameter corresponding to the signal class includes theencoding/decoding characteristic parameter corresponding to thepredicted class, and the encoding/decoding characteristic parametercorresponding to the harmonic class, when the number of sub-bands havinga peak-to-average ratio greater than the first threshold is greater thanthe first predetermined number, and the encoding/decoding characteristicparameter of the current frame corresponding to the harmonic class meetsthe value requirement of the preset encoding/decoding characteristicparameter corresponding to the harmonic class, it is determined that thesignal class of the high-frequency band signal of the current frame isthe harmonic class. When the number of sub-bands having apeak-to-average ratio greater than the first threshold is not greaterthan the first predetermined number, the number of sub-bands having apeak-to-average ratio smaller than the second threshold is not greaterthan the second predetermined number, and the encoding/decodingcharacteristic parameter of the current frame corresponding to thepredicted class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to thepredicted class, it is determined that the signal class of thehigh-frequency band signal of the current frame is the predicted class.The first threshold and the second threshold may be the same ordifferent.

In still another implementation, a full-frequency time-domain signal ofthe current frame is divided into N sub-frames, and when energy of onesub-frame is greater than a certain number of times of energy of aprevious sub-frame of the sub-frame, it is determined that the signalclass of the high-frequency band signal of the current frame is atransient class.

In the embodiment of the present invention, during signalclassification, it is determined according to a value requirement of apreset encoding/decoding characteristic parameter corresponding to asignal class, whether a value of an encoding/decoding characteristicparameter of a current frame meets the value requirement of theencoding/decoding characteristic parameter, so as to determine whether asignal class of a high-frequency band signal of the current frame is thesignal class corresponding to the encoding/decoding characteristicparameter, and in this way, encoding/decoding characteristics ofdifferent signal classes are taken into consideration during signalclassification, thereby making the signal classification more accurate.

To make the technical solution provided in the embodiment of the presentinvention clearer, the technical solution is described in detail belowthrough the following embodiment.

201: The encoder divides a full-frequency time-domain signal of thecurrent frame into N sub-frames.

202: The encoder calculates energy or amplitude of each sub-frame.

203: The encoder determines whether a specified sub-frame exists in thecurrent frame, and if yes, perform step 204; if not, perform step 205.Energy of the specified sub-frame is greater than a certain number oftimes of energy of a previous sub-frame of the specified sub-frame, oramplitude of the specified sub-frame is greater than a certain number oftimes of amplitude of the previous sub-frame of the specified sub-frame.

For example, energy of a certain sub-frame in the current frame in theencoder is E_(cur), energy of a previous sub-frame of the sub-frame isE_(prev), a predetermined number of times is preset at the encoder andis assumed to be a, and generally, a>5; if E_(cur)>a×E_(prev), thesub-frame is the specified sub-frame.

204: The encoder determines that the signal class of the high-frequencyband signal of the current frame is the transient class, and the processis ended.

Because one sub-frame includes a high-frequency band part and alow-frequency band part, and generally energy of the low-frequency bandpart is greater than that of the high-frequency band part, it is assumedthat, for two sequential sub-frames, that is, a sub-frame 1 and asub-frame 2, energy of the high-frequency band part of the sub-frame 1is 1, energy of the high-frequency band part of the sub-frame 2 is 6,energy of the low-frequency band part of the sub-frame 1 is 100, energyof the low-frequency band part of the sub-frame 2 is 100, energy of thesub-frame 1 is 101, and energy of the sub-frame 2 is 106. Assuming thata predetermined number of times is 5, by adopting the solution of step203, the energy of the sub-frame 2 is not greater than the predeterminednumber of times of the energy of the sub-frame 1, and therefore, thesub-frame 2 is not the specified sub-frame. A solution in the prior artis to determine whether the specified sub-frame exists in thehigh-frequency band signal of the current frame, and according to thesolution in the prior art, the high-frequency band energy of thesub-frame 2 is greater than the predetermined number of times of thehigh-frequency band energy of the sub-frame 1, and therefore, thesub-frame 2 is the specified sub-frame. In this way, in view of thewhole frequency band of a data frame, only when there is a significantenergy jump between the high-frequency band parts of neighboringsub-frames, it may be determined that the data frame is of the transientclass. It can be seen that the technical solution of determining whetherthe data frame is of the transient class according to the embodiment ofthe present invention provides a more accurate signal classificationresult.

205: The encoder divides a high-frequency band frequency-domain signalof the current frame into M sub-bands.

Before step 205, the encoder needs to divide the current frame into alow-frequency band signal and a high-frequency band signal.

206: The encoder determines whether the number of sub-bands having apeak-to-average ratio greater than a first threshold in thehigh-frequency band frequency-domain signal of the current frame isgreater than a first predetermined number, and if yes, perform step 207;if not, perform step 208.

207: The encoder determines that the signal class of the high-frequencyband signal of the current frame is the harmonic class, and the processis ended.

208: The encoder determines whether the number of sub-bands having apeak-to-average ratio smaller than a second threshold in thehigh-frequency band frequency-domain signal of the current frame isgreater than a second predetermined number, and if yes, perform step209; if not, perform step 211.

The first predetermined number and the second predetermined number areempirical values obtained through experience, and may be the same ordifferent.

209: The encoder obtains a correlation parameter between energy oramplitude of the high-frequency band frequency-domain signal and energyor amplitude of the low-frequency band frequency-domain signal of thecurrent frame, and determines whether a value of the correlationparameter between the energy or amplitude of the high-frequency bandfrequency-domain signal and the energy or amplitude of the low-frequencyband frequency-domain signal of the current frame is greater than apredetermined energy threshold or amplitude threshold, and if yes,perform step 210; if not, perform step 211.

The specific process of obtaining the value the correlation parameterbetween the energy or amplitude of the high-frequency bandfrequency-domain signal and the energy or amplitude of the low-frequencyband frequency-domain signal of the current frame includes, but is notlimited to, the following two manners.

In the first manner, the encoder obtains values of correlationparameters between energy or amplitude of sub-bands of thehigh-frequency band signal and energy or amplitude of sub-bands of thelow-frequency band signal respectively corresponding to the sub-bands,calculates a mean of the obtained values of the correlation parameters,and uses the mean as the value of the correlation parameter between theenergy or amplitude of the high-frequency band frequency-domain signaland the energy or amplitude of the low-frequency band frequency-domainsignal of the current frame.

In this manner, the encoder and the decoder already predetermine amapping relationship between a certain sub-band of the high-frequencyband signal and a certain sub-band of the low-frequency band signal, andaccordingly, the encoder determines, according to the mappingrelationship, a value of a correlation parameter between energy oramplitude of a certain sub-band of the high-frequency band signal and asub-band of the low-frequency band signal corresponding to the sub-band,calculates by analogy values of correlation parameters between energy oramplitude of sub-bands of the high frequency band and energy oramplitude of corresponding sub-bands of the low frequency band, and thenobtains a mean of the calculated values of the correlation parameters,so as to obtain the value of the correlation parameter between theenergy or amplitude of the high-frequency band frequency-domain signaland the energy or amplitude of the low-frequency band frequency-domainsignal.

In this manner, the encoder may specifically obtain values ofcorrelation parameters between energy or amplitude of sub-bands of thehigh-frequency band signal and energy or amplitude of sub-bands of thelow-frequency band signal respectively corresponding to the sub-bands,according to ratios of energy or amplitude of sub-bands of thehigh-frequency band signal to energy or amplitude of sub-bands of thelow-frequency band signal respectively corresponding to the sub-bands,and generally, if the ratio is close to 1, it indicates a strongcorrelation between the two, and the value of the correlation parameteris large, otherwise, it indicates a weak correlation between the two,and the value of the correlation parameter is small, or, may calculatethe values of the correlation parameters according to absolute values ofdifferences between energy or amplitude of sub-bands of thehigh-frequency band signal and energy or amplitude of sub-bands of thelow-frequency band signal respectively corresponding to the sub-bands,and generally, if the absolute value is small, it indicates a strongcorrelation between the two, and the value of the correlation parameteris large, otherwise, it indicates a weak correlation between the two,and the value of the correlation parameter is small.

In the second manner, the encoder respectively determines a sub-band ofthe low-frequency band signal that is most correlated to energy oramplitude of each sub-band of the high-frequency band signal, obtains avalue of a correlation parameter between energy or amplitude of eachsub-band of the high-frequency band signal and energy or amplitude ofthe determined most correlated sub-band of the low-frequency bandsignal, calculates a mean of the obtained values of the correlationparameters, and uses the mean as the value of the correlation parameterbetween the energy or amplitude of the high-frequency bandfrequency-domain signal and the energy or amplitude of the low-frequencyband frequency-domain signal of the current frame.

This manner is described below by using an example.

It is assumed that, the high-frequency band signal includes 10sub-bands, the low-frequency band signal includes 10 sub-bands, asub-band that is most correlated to energy or amplitude of the firstsub-band of the high frequency band is searched from sub-bands of thelow-frequency band signal, and a value of a correlation parameterbetween the two sub-bands is obtained. Likewise, a sub-band that is mostcorrelated to energy or amplitude of the second sub-band of the highfrequency band is searched from the sub-bands of the low frequency band,and a value of a correlation parameter between the two sub-bands isobtained, and in this way, 10 correlation parameter values are obtainedby analogy, and a mean of the 10 correlation parameters is calculatedand used as the value of the correlation parameter between the energy oramplitude of the high-frequency band frequency-domain signal and theenergy or amplitude of the low-frequency band frequency-domain signal.

In this manner, the specific manner of obtaining the values of thecorrelation parameters between the energy or amplitude of the sub-bandsof the high-frequency band signal and the energy or amplitude of themost correlated sub-bands of the low-frequency band signal is similar tothe first manner, so the details will not be described herein again.

The number of sub-bands may be 1 or more, and when the number ofsub-band is 1, the value of the correlation parameter is directlycalculated for the whole frequency band.

210: The encoder determines that the signal class of the high-frequencyband signal of the current frame is the noise class, and the process isended.

211: The encoder obtains a value of a correlation parameter between afrequency-domain coefficient of a high-frequency band excitationspectrum and a frequency-domain coefficient of a low-frequency bandexcitation spectrum of the current frame, and determines whether thevalue of the correlation parameter between the frequency-domaincoefficient of the high-frequency band excitation spectrum and thefrequency-domain coefficient of the low-frequency band excitationspectrum is greater than a certain predetermined threshold, and if yes,perform step 212; if not, perform step 213.

The value of the correlation parameter between the frequency-domaincoefficient of the high-frequency band excitation spectrum and thefrequency-domain coefficient of the low-frequency band excitationspectrum of the current frame may be obtained by using a normalizedcross-correlation algorithm.

In an implementation, the value of the correlation parameter between thefrequency-domain coefficient of the high-frequency band excitationspectrum and the frequency-domain coefficient of the low-frequency bandexcitation spectrum of the current frame may be obtained in thefollowing manner. The encoder respectively determines a sub-band of thelow-frequency band signal that is most correlated to a frequency-domaincoefficient of an excitation spectrum of each sub-band of thehigh-frequency band signal of the current frame, obtains a value of acorrelation parameter between the frequency-domain coefficient of theexcitation spectrum of each sub-band of the high-frequency band signaland an frequency-domain coefficient of an excitation spectrum of thedetermined most correlated sub-band of the low-frequency band signal,and calculates a mean of the obtained values of the correlationparameters, so as to obtain the value of the correlation parameterbetween the frequency-domain coefficient of the high-frequency bandexcitation spectrum and the frequency-domain coefficient of thelow-frequency band excitation spectrum of the current frame.

It is assumed that the high-frequency band excitation spectrum includes2 sub-bands, the low-frequency band excitation spectrum includes 5sub-bands, each sub-band of the high frequency band includes 20frequency-domain coefficients, and each sub-band of the low frequencyband includes 40 frequency-domain coefficients. By using the followingequation, normalized correlation parameter values of 1st-20thfrequency-domain coefficients, 2nd-21st frequency-domain coefficients,3rd-22nd frequency-domain coefficients, . . . , and 21st-40thfrequency-domain coefficients in 40 frequency-domain coefficients ofeach sub-band of the low-frequency band signal and 20 frequency-domaincoefficients of the first sub-band of the high frequency band aredetermined, and a maximum value among the determined normalizedcorrelation parameter values is obtained. Likewise, normalizedcorrelation parameter values of the 1st-20th frequency-domaincoefficients, 2nd-21st frequency-domain coefficients, 3rd-22ndfrequency-domain coefficients, . . . , and 21st-40th frequency-domaincoefficients in the 40 frequency-domain coefficients of each sub-band ofthe low-frequency band signal and 20 frequency-domain coefficients ofthe second sub-band of the high frequency band are determined, and amaximum value among the determined normalized correlation parametervalues is obtained. A mean of the two maximum values is calculated, soas to obtain the value of the correlation parameter between thefrequency-domain coefficient of the high-frequency band excitationspectrum and the frequency-domain coefficient of the low-frequency bandexcitation spectrum of the current frame.

$\{ {\sum\limits_{i = 1}^{20}{( {a_{i}*b_{i}} )/\sqrt{\sum\limits_{i = 1}^{20}{a_{i}^{2}*{\sum\limits_{j = 1}^{20}b_{j}^{2}}}}}} \}$

Here, a_(i) and b_(i) are respectively a certain frequency-domaincoefficient in a sub-band of the low-frequency band signal and a certainfrequency-domain coefficient of a sub-band of the high-frequency bandsignal, for example, when normalized correlation parameter values of2nd-21st frequency-domain coefficients of a certain sub-band of thelow-frequency band signal and 20 frequency-domain coefficients of thehigh-frequency band signal are calculated, a₁ is the 2ndfrequency-domain coefficient of a certain sub-band of the low-frequencyband signal, a₂ is the 3rd frequency-domain coefficient of the sub-band,a₂₀ is the 21st frequency-domain coefficient of the sub-band, and b₁ tob₂₀ are 20 frequency-domain coefficients in a certain sub-band of thehigh-frequency band signal.

Alternatively, in another implementation, the encoder in this step mayalso obtain a value of a correlation parameter between an absolute valueof the frequency-domain coefficient of the high-frequency bandexcitation spectrum and an absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum of the currentframe, and determine whether the value of the correlation parameterbetween the absolute value of the frequency-domain coefficient of thehigh-frequency band excitation spectrum and the absolute value of thefrequency-domain coefficient of the low-frequency band excitationspectrum is greater than a certain threshold, and if yes, perform step212; if not, perform step 213.

212: The encoder determines that the signal class of the high-frequencyband signal of the current frame is the predicted class, and the processis ended.

213: The encoder determines that the signal class of the high-frequencyband signal of the current frame is the normal class.

It should be noted that, the order of the above determination steps isnot fixed, but may be changed, for example, step 206-step 211 may beperformed first, and when step 211 is performed, if the determiningresult is yes, step 212 is performed, and if the determining result isnot, step 201-204 is performed, where when the determining result ofstep 203 is yes, it is determined that the signal class of thehigh-frequency band signal of the current frame is the transient class,and when the determining result of step 203 is not, it is determinedthat the signal class of the high-frequency band signal of the currentframe is the normal class.

In the embodiment of the present invention, during signalclassification, encoding/decoding characteristics of the high-frequencyband signal of the current frame are taken into consideration, so thatwhen energy or amplitude of the high-frequency band frequency-domainsignal and energy or amplitude of the low-frequency bandfrequency-domain signal of the current frame are strongly correlated,the high-frequency band signal is classified into the noise class. Whenthe frequency-domain coefficient of the high-frequency band excitationspectrum and the frequency-domain coefficient of the low-frequency bandexcitation spectrum of the current frame are strongly correlated, thehigh-frequency band signal is classified into the predicted class,thereby making the signal classification more accurate, while in theprior art, the class is determined only according to the peak-to-averageratio, and encoding/decoding characteristics of the signal class are nottaken into consideration, and therefore, data frames havingencoding/decoding characteristics of the noise class may be classifiedinto the normal class, resulting in an inaccurate classification result.Further, when it is determined whether the high-frequency band signal ofthe current frame is of the transient class, determination is performedbased on sub-frames of the full-frequency band of the current frame, butis not performed only based on sub-bands in the high-frequency bandsignal, thereby providing a more accurate determining result. Further,because the signal classification is more accurate, theencoding/decoding performance is improved when the same number of bitsis used, for example, it is determined by the signal classificationmethod in the prior art that the signal class of the high-frequency bandsignal of a certain frame is the normal class, while it is determined bythe signal classification method provided in the present applicationthat the signal class of the high-frequency band signal of the frame isthe noise class, and if the encoder and the decoder predetermine amapping relationship between a certain sub-band of the high-frequencyband signal and a certain sub-band of the low-frequency band signal, theencoder only needs to send a ratio of energy or amplitude of thesub-band of the high-frequency band signal to energy or amplitude of thesub-band of the low-frequency band signal, and does not need to transmitother information, thereby reducing the number of bits.

Alternatively, in another implementation, in step 211, the encoder mayobtain a value of a correlation parameter between a frequency-domaincoefficient of the high-frequency band signal of the current frame and afrequency-domain coefficient of the low-frequency band signal, anddetermine whether the value of the correlation parameter between thefrequency-domain coefficient of the high-frequency band signal and thefrequency-domain coefficient of the low-frequency band signal is greaterthan a certain threshold, and if yes, perform step 212; if not, performstep 213. Specifically, the value of the correlation parameter betweenthe frequency-domain coefficient of the high-frequency band signal andthe frequency-domain coefficient of the low-frequency band signal of thecurrent frame may be obtained in the following manner. The encoderrespectively determines a sub-band of the low-frequency band signal thatis most correlated to a frequency-domain coefficient of each sub-band ofthe high-frequency band signal of the current frame, obtains a value ofa correlation parameter between the frequency-domain coefficient of eachsub-band of the high-frequency band signal and the frequency-domaincoefficient of the determined sub-band of the low-frequency band signalthat is most correlated to the sub-band, calculates a mean of theobtained values of the correlation parameters, and uses the mean as thevalue of the correlation parameter between the frequency-domaincoefficient of the high-frequency band signal and the frequency-domaincoefficient of the low-frequency band signal of the current frame.

Alternatively, in another implementation, in step 211, the encoder mayobtain a value of a correlation parameter between an absolute value ofthe frequency-domain coefficient of the high-frequency band signal andan absolute value of the frequency-domain coefficient of thelow-frequency band signal of the current frame, and determine whetherthe value of the correlation parameter between the absolute value of thefrequency-domain coefficient of the high-frequency band signal and theabsolute value of the frequency-domain coefficient of the low-frequencyband signal is greater than a certain threshold, and if yes, performstep 212; if not, perform step 213.

Alternatively, in another implementation, when the number of sub-bandshaving a peak-to-average ratio smaller than the second threshold isgreater than the second predetermined number, and a value of theencoding/decoding characteristic parameter of the current framecorresponding to the noise class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thenoise class (that is, the correlation parameter between the amplitude ofthe low-frequency band frequency-domain signal and the amplitude of thehigh-frequency band frequency-domain signal of the current frame meetsthe preset value requirement, or the correlation parameter between theenergy of the low-frequency band frequency-domain signal and the energyof the high-frequency band frequency-domain signal meets the presetvalue requirement), it is determined that the signal class of thehigh-frequency band signal of the current frame is the noise class.

When the number of sub-bands having a peak-to-average ratio greater thanthe first threshold is greater than the first predetermined number, andthe value of the encoding/decoding characteristic parameter of thecurrent frame corresponding to the harmonic class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the harmonic class (that is, the correlation parameterbetween the frequency-domain coefficient of the low-frequency bandsignal and the frequency-domain coefficient of the high-frequency bandsignal, or, the correlation parameter between the absolute value of thefrequency-domain coefficient of the low-frequency band signal and theabsolute value of the frequency-domain coefficient of the high-frequencyband signal, or, the correlation parameter between the frequency-domaincoefficient of the low-frequency band excitation spectrum and thefrequency-domain coefficient of the high-frequency band excitationspectrum, or, the correlation parameter between the absolute value ofthe frequency-domain coefficient of the low-frequency band excitationspectrum and the absolute value of the frequency-domain coefficient ofthe high-frequency band excitation spectrum meets the preset valuerequirement), it is determined that the signal class of thehigh-frequency band signal of the current frame is the harmonic class.

When the number of sub-bands having a peak-to-average ratio greater thanthe first threshold is not greater than the first predetermined number,when the number of sub-bands having a peak-to-average ratio smaller thanthe second threshold is not greater than the second predeterminednumber, and the value of the encoding/decoding characteristic parameterof the current frame corresponding to the predicted class meets thevalue requirement of the preset encoding/decoding characteristicparameter corresponding to the predicted class (that is, the correlationparameter between the frequency-domain coefficient of the low-frequencyband signal and the frequency-domain coefficient of the high-frequencyband signal, or, the correlation parameter between the absolute value ofthe frequency-domain coefficient of the low-frequency band signal andthe absolute value of the frequency-domain coefficient of thehigh-frequency band signal, or, the correlation parameter between thefrequency-domain coefficient of the low-frequency band excitationspectrum and the frequency-domain coefficient of the high-frequency bandexcitation spectrum, or, the correlation parameter between the absolutevalue of the frequency-domain coefficient of the low-frequency bandexcitation spectrum and the absolute value of the frequency-domaincoefficient of the high-frequency band excitation spectrum meets thepreset value requirement), it is determined that the signal class of thehigh-frequency band signal of the current frame is the predicted class.

When it is already determined by using the above technical solution thata data frame does not belong to the transient class, the noise class,the harmonic class and the predicted class, it may be determined thatthe data frame belongs to the normal class.

The value requirement of the encoding/decoding characteristic parametercorresponding to the harmonic class and the value requirement of theencoding/decoding characteristic parameter corresponding to thepredicted class may be the same or different, which does not influencethe implementation of the present invention.

Referring to FIG. 3, an embodiment of the present invention provides asignal classification device, where the device specifically includes adivision unit 10, configured to divide a current frame into alow-frequency band signal and a high-frequency band signal, a judgmentunit 20, configured to determine, according to a value requirement of apreset encoding/decoding characteristic parameter corresponding to asignal class, whether an encoding/decoding characteristic parameter ofthe current frame corresponding to the signal class meets the valuerequirement of the encoding/decoding characteristic parameter. That is,the judgment unit 20 determines according to the value requirement ofthe preset encoding/decoding characteristic parameter corresponding tothe signal class, whether a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to thesignal class meets the value requirement of the encoding/decodingcharacteristic parameter, and a determination unit 30, configured todetermine according to a determining result whether a signal class ofthe high-frequency band signal of the current frame is a signal classcorresponding to the encoding/decoding characteristic parameter, wherethe signal class corresponding to the encoding/decoding characteristicparameter is a signal class having encoding/decoding characteristicsrepresented by the encoding/decoding characteristic parameter.

In an implementation, the preset encoding/decoding characteristicparameter corresponding to the signal class includes anencoding/decoding characteristic parameter corresponding to a noiseclass, where the encoding/decoding characteristic parametercorresponding to the noise class is one of: a correlation parameterbetween an amplitude of a low-frequency band frequency-domain signal andan amplitude of a high-frequency band frequency-domain signal, and acorrelation parameter between energy of the low-frequency bandfrequency-domain signal and energy of the high-frequency bandfrequency-domain signal. At this time, the signal classification devicemay further include a second peak-to-average ratio judgment unit 40,configured to determine whether the number of sub-bands having apeak-to-average ratio smaller than a second threshold in thehigh-frequency band signal of the current frame is greater than a secondpredetermined number, and the determination unit includes a noise classdetermining unit 31, configured to determine that the signal class ofthe high-frequency band signal of the current frame is the noise class,when the number of sub-bands having a peak-to-average ratio smaller thanthe second threshold is greater than the second predetermined number,and a value of the encoding/decoding characteristic parameter of thecurrent frame corresponding to the noise class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the noise class. Alternatively, the signalclassification device may not include the second peak-to-average ratiojudgment unit 40, and other devices or chips are used to determinewhether the number of sub-bands having a peak-to-average ratio smallerthan the second threshold in the high-frequency band signal of thecurrent frame is greater than the second predetermined number, andnotify the signal classification device of the determining result.

In another implementation, the preset encoding/decoding characteristicparameter corresponding to the signal class includes anencoding/decoding characteristic parameter corresponding to a predictedclass, or an encoding/decoding characteristic parameter corresponding toa harmonic class, where the corresponding description of theencoding/decoding characteristic parameter corresponding to thepredicted class and the encoding/decoding characteristic parametercorresponding to the harmonic class is the same as that in the methodembodiment, so the details will not be described herein again. Thesignal classification device may further include a first peak-to-averageratio judgment unit 50, configured to determine whether the number ofsub-bands having a peak-to-average ratio greater than a first thresholdin the high-frequency band signal of the current frame is greater than afirst predetermined number, and when the preset encoding/decodingcharacteristic parameter corresponding to the signal class includes theencoding/decoding characteristic parameter corresponding to the harmonicclass, the determination unit includes a harmonic class determining unit32, configured to determine that the signal class of the high-frequencyband signal of the current frame is the harmonic class, when the numberof sub-bands having a peak-to-average ratio greater than the firstthreshold is greater than the first predetermined number, and a value ofthe encoding/decoding characteristic parameter of the current framecorresponding to the harmonic class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to theharmonic class. When the preset encoding/decoding characteristicparameter corresponding to the signal class includes theencoding/decoding characteristic parameter corresponding to thepredicted class, the determination unit includes a predicted classdetermining unit 33, configured to determine that the signal class ofthe high-frequency band signal of the current frame is the predictedclass, when the number of sub-bands having a peak-to-average ratiogreater than the first threshold is not greater than the firstpredetermined number, and a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to thepredicted class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to thepredicted class. Alternatively, the signal classification device may notinclude the first peak-to-average ratio judgment unit 50, and otherdevices or chips are used to determine whether the number of sub-bandshaving a peak-to-average ratio greater than the first threshold in thehigh-frequency band signal of the current frame is greater than thefirst predetermined number, and notify the signal classification deviceof the determining result. In an exemplary implementation, the predictedclass determining unit is specifically configured to determine that thesignal class of the high-frequency band signal of the current frame isthe predicted class, when the number of sub-bands having apeak-to-average ratio smaller than the second threshold is not greaterthan the second predetermined number, the number of sub-bands having apeak-to-average ratio greater than the first threshold is not greaterthan the first predetermined number, and a value of theencoding/decoding characteristic parameter of the current framecorresponding to the predicted class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thepredicted class. At this time, the signal classification device mayfurther include a second peak-to-average ratio judgment unit 40,configured to determine whether the number of sub-bands having apeak-to-average ratio smaller than a second threshold in thehigh-frequency band signal of the current frame is greater than a secondpredetermined number.

In an implementation, the preset encoding/decoding characteristicparameter corresponding to the signal class includes anencoding/decoding characteristic parameter corresponding to a predictedclass, and an encoding/decoding characteristic parameter correspondingto a harmonic class, where the corresponding description of theencoding/decoding characteristic parameter corresponding to thepredicted class and the encoding/decoding characteristic parametercorresponding to the harmonic class is the same as that in the methodembodiment, so the details are not described herein again. At this time,the signal classification device may further include a secondpeak-to-average ratio judgment unit 40, configured to determine whetherthe number of sub-bands having a peak-to-average ratio smaller than asecond threshold in the high-frequency band signal of the current frameis greater than a second predetermined number, and a firstpeak-to-average ratio judgment unit 50, configured to determine whetherthe number of sub-bands having a peak-to-average ratio greater than afirst threshold in the high-frequency band signal of the current frameis greater than a first predetermined number. and the determination unitincludes a harmonic class determining unit 32, configured to determinethat the signal class of the high-frequency band signal of the currentframe is the harmonic class, when the number of sub-bands having apeak-to-average ratio greater than the first threshold is greater thanthe first predetermined number, and a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to theharmonic class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to the harmonicclass, and a predicted class determining unit 33, configured todetermine that the signal class of the high-frequency band signal of thecurrent frame is the predicted class, when the number of sub-bandshaving a peak-to-average ratio greater than the first threshold is notgreater than the first predetermined number, the number of sub-bandshaving a peak-to-average ratio smaller than the second threshold is notgreater than the second predetermined number, and a value of theencoding/decoding characteristic parameter of the current framecorresponding to the predicted class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thepredicted class. Alternatively, the signal classification device may notinclude the second peak-to-average ratio judgment unit 40 and the firstpeak-to-average ratio judgment unit 50, and other devices or chips areused to perform judgment and then notify the signal classificationdevice of the determining result.

It should be noted that, although the predicted class determining unit33, the harmonic class determining unit 32 and the noise classdetermining unit 31 are drawn in FIG. 7, the determination unit 30 mayonly include any one or two units in specific implementations.

In still another implementation, the device further includes a transientclass determining unit, configured to divide a full-frequencytime-domain signal of the current frame into N sub-frames, and whenenergy of one sub-frame is greater than a certain number of times ofenergy of a previous sub-frame of the sub-frame, determine that thesignal class of the high-frequency band signal of the current frame is atransient class.

In the embodiment of the present invention, during signalclassification, it is determined whether the signal class of the currentframe is the signal class corresponding to the encoding/decodingcharacteristic parameter by determining whether the value of theencoding/decoding characteristic parameter of the current frame meetsthe preset requirement, and in this way, encoding/decodingcharacteristics of different signal classes are taken into considerationduring signal classification, thereby making the signal classificationmore accurate. Further, because the signal classification for a dataframe is more accurate, the number of bits transmitted after the dataframe is encoded is reduced. If it is determined by the signalclassification method in the prior art that a certain data frame is anormal frame, while it is determined by the signal classification methodin the present application that the data frame is a noise frame, and ifthe encoder and the decoder predetermine a mapping relationship betweena certain sub-band of the high-frequency band signal and a certainsub-band of the low-frequency band signal, the encoder only needs tosend a ratio of the frequency-domain envelope of the sub-band of thehigh-frequency band signal to the frequency-domain envelope of thesub-band of the low-frequency band signal, and does not need to sendinformation related to excitation spectrums, thereby reducing the numberof bits.

The signal classification device may be located at the system side, forexample, within a base station, and may specifically be a chip or asoftware module within the base station. Alternatively, the signalclassification device may be located at the terminal side, and mayspecifically be a chip or a software module.

In band-based encoding/decoding algorithms, generally differentalgorithms are used for encoding/decoding the low-frequency band signaland encoding/decoding the high-frequency band signal, and generally thealgorithm used for encoding/decoding the low-frequency band signal isCELP (Code Excited Linear Prediction, code excited linear prediction),which may specifically be ACELP (Algebraic Code Excited LinearPrediction, algebraic code excited linear prediction), QCELP (QualcommCode Excited Linear Prediction) or RCELP (Relaxed code excited linearprediction). Due to the CELP algorithm, the encoder attenuates energy ofthe low-frequency band signal when encoding the low-frequency bandsignal. The existing algorithm for encoding/decoding the high-frequencyband signal does not attenuate energy of the high-frequency band signal.However, if the energy of the high-frequency band signal is notattenuated, sometimes the signal obtained by the decoder by decoding isunpleasant to hear. Therefore, to solve the above technical problem, thefollowing embodiments of the present invention provide encoding anddecoding methods and encoding and decoding devices, to attenuate theenergy of the high-frequency band signal accordingly.

Referring to FIG. 4, an embodiment of the present invention provides anencoding method, which mainly includes the following.

401: Divide a current frame into a low-frequency band signal and ahigh-frequency band signal.

The embodiment of the present invention is implemented by an encoder.

Specifically, the low-frequency band signal and the high-frequency bandsignal are relative concepts, and generally, an input signal is dividedby a QMF filter from the center frequency of the input signal into alow-frequency band signal and a high-frequency band signal by a QMFfilter. However, the present invention is not limited thereto, and theinput signal may also be divided from other frequencies into alow-frequency band signal and a high-frequency band signal in otherprocessing manners.

402: Attenuate the high-frequency band signal or a to-be-encodedcharacteristic parameter of the high-frequency band signal according toan energy attenuation value of the low-HW frequency band signal, wherethe energy attenuation value indicates energy attenuation of thelow-frequency band signal caused by encoding of the low-frequency bandsignal.

Before this step, the method further includes determining a signal classof the high-frequency band signal of the current frame, where the signalclass may be specifically determined by using a signal class determiningmethod provided in the prior art, or the signal class determining methodprovided in the above embodiments of the present invention, which doesnot influence the implementation of the present invention.

The high-frequency band signal of the current frame may be ahigh-frequency band time-domain signal of the current frame or ahigh-frequency band frequency-domain signal of the current frame. Theto-be-encoded characteristic parameter of the high-frequency band signalof the current frame may be an energy to-be-encoded characteristicparameter of the high-frequency band signal, and may specifically be ato-be-encoded time domain envelope or a to-be-encoded frequency domainenvelope of the high-frequency band signal of the current frame.

The high-frequency band signal or the to-be-encoded characteristicparameter of the high-frequency band signal may specifically beattenuated according to the energy attenuation value and the signalclass of the high-frequency band signal of the current frame. In anotherimplementation, the encoder may attenuate high-frequency band signals ofall signal classes or to-be-encoded characteristic parameters of thehigh-frequency band signals. However, because signal classes of thecurrent frame are different, the attenuated high-frequency band signalof the current frame or the attenuated to-be-encoded characteristicparameters of the high-frequency band signal of the current frame mayalso be different. For details, refer to the description of theembodiment shown in FIG. 5. In still another implementation, onlysignals of several classes are attenuated, or only signals of a certainclass are attenuated, which does not influence the implementation of thepresent invention.

In a specific implementation, the signal class of the high-frequencyband signal of the current frame may include a noise class, a predictedclass, a transient class, a harmonic class and a normal class. Inanother specific implementation, the signal class of the high-frequencyband signal of the current frame may include the noise class, thepredicted class, the transient class, the harmonic class, a fricativeclass and a voiced class. The difference between the signal classes inthe two specific implementations lies in that, in the latter on, thenormal class is divided into the fricative class and the voiced class.

Manners of obtaining the energy attenuation value include, but are notlimited to, the following two manners.

In the first manner, the encoder encodes the low-frequency band signalof the current frame and locally decodes a result of encoding thelow-frequency band signal, and uses a ratio of energy of thelow-frequency band signal to energy of a signal obtained by the localdecoding as the energy attenuation value. The energy attenuation valuedetermined in this manner is the most accurate.

In the second manner, the energy attenuation value is preset at theencoder, and the energy attenuation value is obtained according toratios of energy of multiple low-frequency band signals of thesame-class frame to energy of signals obtained by decoding results ofencoding the low-frequency band signals of the same-class frame, whichmay specifically be obtaining a value by training according to theratios by using an LBG algorithm, and using the value as the energyattenuation value, where the same-class frame is a data frame of thesame signal class as the high-frequency band signal of the currentframe.

In this manner, a corresponding energy attenuation value may be presetfor all the signal classes, or a corresponding energy attenuation valuemay be preset only for signal classes requiring attenuation. Forexample, in a specific implementation, if only signals of a fricativeclass need to be attenuated, it only needs to preset an energyattenuation value of the signals of the fricative class.

403: Encode the attenuated high-frequency band signal or the attenuatedto-be-encoded characteristic parameter of the high-frequency bandsignal.

The encoder in the embodiment of the present invention attenuates thehigh-frequency band signal or the to-be-encoded characteristic parameterof the high-frequency band signal according to the energy attenuationvalue of the low-frequency band signal of the current frame, and encodesand sends the attenuation result to a decoder, so that energy of thehigh-frequency band signal obtained by the decoder by decoding isattenuated accordingly. In this way, the high-frequency band signal ispleasant to ears of the user after being combined with the low-frequencyband signal, thereby improving user experience.

The technical solution provided in the above embodiment of the presentinvention is described in detail below through an embodiment shown inFIG. 5.

501: The encoder encodes the low-frequency band signal of the currentframe and locally decodes a result of encoding the low-frequency bandsignal, and uses a ratio of energy of the low-frequency band signal toenergy of a signal obtained by the local decoding as the energyattenuation value of the low-frequency band signal of the current frame.

502: The encoder determines a signal class of the high-frequency bandsignal of the current frame.

The signal class may be specifically determined by using a signal classdetermining method provided in the prior art, or the signal classdetermining method provided in the above embodiments of the presentinvention.

503: The encoder attenuates the high-frequency band signal of thecurrent frame or the to-be-encoded characteristic parameter of thehigh-frequency band signal according to the signal class of thehigh-frequency band signal of the current frame and the energyattenuation value.

In this step, regardless of the signal class of the current frame, theencoder uses the energy attenuation value to attenuate the energy of thehigh-frequency band signal; however, for different signal classes,different processing manners are used. Specifically, when the class ofthe high-frequency band signal of the current frame is the transientclass, the high-frequency band time-domain signal or the to-be-encodedtime domain envelope of the high-frequency band signal is attenuatedaccording to the energy attenuation value. When the class of thehigh-frequency band signal of the current frame is the fricative class,the harmonic class or the normal class, the high-frequency bandfrequency-domain signal or the to-be-encoded frequency domain envelopeof the high-frequency band signal is attenuated according to the energyattenuation value.

504: The encoder encodes an attenuation result and an identification ofthe signal class of the high-frequency band signal of the current frame,to obtain a bit stream.

505: The encoder sends the bit stream.

The encoder in the embodiment of the present invention attenuates thehigh-frequency band signal of the current frame or the to-be-encodedcharacteristic parameter of the high-frequency band signal according tothe energy attenuation value of the low-frequency band signal of thecurrent frame, and encodes and sends the attenuation result to thedecoder, so that energy of the high-frequency band signal obtained bythe decoder by decoding is attenuated accordingly. In this way, thehigh-frequency band signal is pleasant to ears of the user after beingcombined with the low-frequency band signal, thereby improving userexperience.

Alternatively, in a specific implementation, a data frame of a specificclass may be attenuated, for example, when the encoder uses the CELPalgorithm to encode a low-frequency band signal of a certain data frame,if the high-frequency band signal of the data frame is of the transientclass, the low-frequency band signal of the data frame generally hassub-frames where an energy jump occurs, and it is generally consideredthat the low-frequency band signal of the data frame is also of thetransient class. The CELP algorithm attenuates greatly the low-frequencyband signal of the transient class, and attenuates slightlylow-frequency band signals of other classes, and in such case, theattenuation of low-frequency band signals of other classes may beignored, and only the attenuation of the low-frequency band signal ofthe transient class is taken into consideration, and in that case, onlywhen the high-frequency band signal of the current frame is of thetransient class, the high-frequency band time-domain signal of thecurrent frame or the to-be-encoded time domain envelope of thehigh-frequency band signal is attenuated, that is, the high-frequencyband time-domain signal of the current frame or the to-be-encoded timedomain envelope of the high-frequency band signal is attenuated.

Alternatively, in still another specific implementation, not only thehigh-frequency band signal of the transient class needs to beattenuated, but also the high-frequency band signal of the fricativeclass needs to be attenuated. Because the normal class may be furtherdivided into the fricative class and the voiced class, when the encoderencodes the low-frequency band signal of the voiced class by using theCELP algorithm, the encoding causes small energy attenuation, and whenthe encoder encodes the low-frequency band signal of the fricativeclass, the encoding causes great energy attenuation. Therefore beforeencoding the high-frequency band signal of the data frame, if theencoder determines that the high-frequency band signal of the data frameis of the fricative class, the encoder needs to attenuate thehigh-frequency band frequency-domain signal of the fricative class orthe to-be-encoded frequency domain envelope of the high-frequency bandsignal of the fricative class, that is, the high-frequency bandfrequency-domain signal of the fricative class or the to-be-encodedfrequency domain envelope of the high-frequency band signal of thefricative class is attenuated.

The energy attenuation value of the low-frequency band signal of thecurrent frame used by the encoder in the above embodiment is a ratio ofenergy of the low-frequency band signal of the current frame to energyof a signal obtained by locally decoding a result of encoding, by theencoder, encoding the low frequency band signal. Alternatively, inanother specific implementation, for different signal classes, differentenergy attenuation values may be obtained by training by using the LBGalgorithm, and then the obtained energy attenuation values are preset atthe encoder and the decoder, for example, when the signal class of thehigh-frequency band signal includes the noise class, the predictedclass, the transient class, the harmonic class and the normal class, oneenergy attenuation value is obtained for the noise class by training,one energy attenuation value is obtained for the predicted class bytraining, one energy attenuation value is obtained for the transientclass by training, and one energy attenuation value is obtained for thenormal class by training. The specific manner of obtaining one energyattenuation value corresponding to a certain signal class by trainingmay be obtaining ratios of energy of multiple low-frequency band signalsof the signal class to energy of signals obtained by decoding, by thedecoder, results of encoding the corresponding low-frequency bandsignals, obtaining one value by training according to the obtainedratios by using the LBG algorithm, and using the value as the energyattenuation value corresponding to the signal class. In still anotherspecific implementation, if the normal signal class is further dividedinto the fricative class and the voiced class, energy attenuation valuesare obtained for the fricative class and the voiced class by training byusing the LBG algorithm and preset at the encoder and the decoder.Alternatively, if only high-frequency band signals of some signalclasses need to be attenuated, for example, only high-frequency bandsignals of the transient class and the fricative class are attenuated,it only needs to preset the energy attenuation value corresponding tothe transient class and the energy attenuation value corresponding tothe fricative class, and does not need to preset energy attenuationvalues corresponding to other classes.

Referring to FIG. 6, an embodiment of the present invention provides adecoding method, which includes the following.

601: Decode a bit stream to obtain a high-frequency band signal of acurrent frame or a characteristic parameter of the high-frequency bandsignal of the current frame.

The embodiment of the present invention is implemented by a decoder.

The high-frequency band signal of the current frame may be ahigh-frequency band time-domain signal of the current frame or ahigh-frequency band frequency-domain signal of the current frame. Thecharacteristic parameter of the high-frequency band signal of thecurrent frame may be a time-domain envelope or a frequency-domainenvelope of the high-frequency band signal of the current frame.

602: Attenuate the high-frequency band signal or the characteristicparameter of the high-frequency band signal according to an energyattenuation value of a low-frequency band signal of the current frame,where the energy attenuation value indicates energy attenuation of thelow-frequency band signal caused by encoding of the low-frequency bandsignal.

The high-frequency band signal or the characteristic parameter of thehigh-frequency band signal may be specifically attenuated according tothe energy attenuation value of the low-frequency band signal of thecurrent frame and the signal class of the high-frequency band signal ofthe current frame. In another implementation, the decoder may attenuatethe high-frequency band signals of all signal classes or characteristicparameters of the high-frequency band signals. However, because signalclasses of the current frame are different, the attenuatedhigh-frequency band signal of the current frame or the attenuatedcharacteristic parameters of the high-frequency band signal of thecurrent frame may also be different. For details, refer to thedescription of the embodiment shown in FIG. 7. In still anotherimplementation, only signals of several classes are attenuated, or onlysignals of a certain class are attenuated, which does not influence theimplementation of the present invention.

For the classification of the signal class of the high-frequency bandsignal, reference is made to the detailed description of the embodimentshown in FIG. 4, so the details will not be described herein again.

Obtaining of the energy attenuation value of the low-frequency bandsignal of the current frame includes, but is not limited to, thefollowing two manners.

In the first manner, the decoder parses the bit stream sent by theencoder to obtain the energy attenuation value, that is, the energyattenuation value of the low-frequency band signal of the current frameis obtained by the encoder and sent to the decoder, and specifically,the encoder may use a ratio of energy of the low-frequency band signalof the current frame to energy of a signal obtained by locally decodinga result of encoding, by the encoder, the low-frequency band signal ofthe current frame as the energy attenuation value.

In the second manner, the energy attenuation value of the low-frequencyband signal of the current frame is preset at the decoder, and theenergy attenuation value is obtained according to ratios of energy ofmultiple low-frequency band signals of the same-class frame to energy ofsignals obtained by decoding results of encoding the low-frequency bandsignals of the same-class frame, which may specifically be obtaining avalue by training according to the ratios by using an LBG algorithm, andusing the value as the energy attenuation value, where the same-classframe is a data frame of the same signal class as the high-frequencyband signal of the current frame.

The decoder in the embodiment of the present invention attenuates,according to the energy attenuation value of the low-frequency bandsignal of the current frame, the high-frequency band signal or thecharacteristic parameter of the high-frequency band signal obtained bydecoding, so that the finally obtained high-frequency band signal ispleasant to ears of the user after being combined with the low-frequencyband signal, thereby improving user experience.

The technical solution provided in the above embodiment of the presentinvention is described in detail below through an embodiment shown inFIG. 7.

701: The decoder receives a bit stream sent by the encoder, where thebit stream includes a result of encoding the high-frequency band signal,an energy attenuation value of the low-frequency band signal of thecurrent frame, and an identification of the signal class of thehigh-frequency band signal of the current frame.

702: The decoder decodes the bit stream to obtain the energy attenuationvalue of the low-frequency band signal of the current frame, the signalclass of the high-frequency band signal of the current frame, and thehigh-frequency band signal of the current frame or a characteristicparameter of the high-frequency band signal of the current frame.

703: The decoder attenuates the high-frequency band signal of thecurrent frame or the characteristic parameter of the high-frequency bandsignal of the current frame according to the energy attenuation value ofthe low-frequency band signal of the current frame and the signal classof the high-frequency band signal of the current frame.

In this embodiment, regardless of the signal class of the current frame,the decoder uses the energy attenuation value of the low-frequency bandsignal of the current frame to attenuate the energy of thehigh-frequency band signal. However, for different signal classes,different processing manners are used. Specifically, when the class ofthe high-frequency band signal of the current frame is the transientclass, the high-frequency band time-domain signal or the time-domainenvelope of the high-frequency band signal is attenuated according tothe energy attenuation value of the low-frequency band signal of thecurrent frame. When the class of the high-frequency band signal of thecurrent frame is the fricative class, the harmonic class or the normalclass, the high-frequency band frequency-domain signal or thefrequency-domain envelope of the high-frequency band signal isattenuated according to the energy attenuation value of thelow-frequency band signal of the current frame.

The decoder in the embodiment of the present invention attenuates thehigh-frequency band signal of the current frame or the characteristicparameter of the high-frequency band signal obtained by decoding, sothat the finally obtained high-frequency band signal is pleasant to earsof the user after being combined with the low-frequency band signal,thereby improving user experience.

Alternatively, in a specific implementation, the decoder may onlyattenuate signals of a specific class, for example, only when thehigh-frequency band signal of the current frame is of the transientclass, the decoder attenuates the high-frequency band time-domain signalof the current frame or the time-domain envelope of the high-frequencyband signal, that is, the high-frequency band time-domain signal of thecurrent frame or the time-domain envelope of the high-frequency bandsignal is attenuated.

Alternatively, in still another specific implementation, not only thehigh-frequency band signal of the transient class needs to beattenuated, but also the high-frequency band signal of the fricativeclass needs to be attenuated. As such, the decoder obtains thehigh-frequency band signal of the fricative class by decoding, and thenattenuates the high-frequency band signal of the fricative class, thatis, the high-frequency band signal of the fricative class is attenuated.Alternatively, the decoder may obtain a frequency-domain envelope of thehigh-frequency band signal of the fricative class by decoding, and thenattenuate the frequency-domain envelope of the high-frequency bandsignal of the fricative class, that is, the frequency-domain envelope ofthe high-frequency band signal of the fricative class is attenuated.

In the above embodiment, the energy attenuation value of thelow-frequency band signal of the current frame is sent by the encoder tothe decoder, and alternatively, in another specific implementation, theenergy attenuation value may be preset at the decoder, that is,different energy attenuation values may be obtained for different signalclasses by training by using the LBG algorithm, and then the obtainedenergy attenuation values are preset at the encoder and the decoder. Thespecific implementation is similar to the description of the foregoingcorresponding part, so the details will not be described herein again.

Referring to FIG. 8, an embodiment of the present invention provides anencoding device, which includes a division unit 100, configured todivide a current frame into a low-frequency band signal and ahigh-frequency band signal, a correction unit 200, configured toattenuate the high-frequency band signal or a to-be-encodedcharacteristic parameter of the high-frequency band signal according toan energy attenuation value of the low-frequency band signal, where theenergy attenuation value indicates energy attenuation of thelow-frequency band signal caused by encoding of the low-frequency bandsignal of the current frame, where the high-frequency band signal of thecurrent frame may be a high-frequency band time-domain signal of thecurrent frame or a high-frequency band frequency-domain signal of thecurrent frame. The to-be-encoded characteristic parameter of thehigh-frequency band signal of the current frame may be an energyto-be-encoded characteristic parameter of the high-frequency bandsignal, and may specifically be a to-be-encoded time domain envelope ora to-be-encoded frequency domain envelope of the high-frequency bandsignal of the current frame, and an encoding unit 300, configured toencode the attenuated high-frequency band signal or the attenuatedto-be-encoded characteristic parameter of the high-frequency bandsignal.

To determine a signal class of the high-frequency band signal of thecurrent frame, the encoding device further includes a signal classdetermining unit 400, configured to determine the signal class of thehigh-frequency band signal of the current frame. At this time, thecorrection unit 200 is configured to attenuate the high-frequency bandsignal or the to-be-encoded characteristic parameter of thehigh-frequency band signal according to the energy attenuation value andthe signal class of the high-frequency band signal.

The correction unit 200 is specifically configured to attenuate ahigh-frequency band time-domain signal or a to-be-encoded time domainenvelope of the high-frequency band signal according to the energyattenuation value, when the class of the high-frequency band signal is atransient class. and/or, the correction unit 200 is specificallyconfigured to attenuate a high-frequency band frequency-domain signal ora to-be-encoded frequency domain envelope of the high-frequency bandsignal according to the energy attenuation value, when the class of thehigh-frequency band signal is a fricative class, a harmonic class or anormal class.

To obtain the energy attenuation value of the current frame, theencoding device may further include an energy attenuation valueobtaining unit 500, configured to encode the low-frequency band signaland locally decoding a result of encoding the low-frequency band signal,and use a ratio of energy of the low-frequency band signal to energy ofa signal obtained by the local decoding as the energy attenuation value,or, an energy attenuation value setting unit 600, configured to set theenergy attenuation value of the current frame, where the energyattenuation value is obtained according to ratios of energy of multiplelow-frequency band signals of the same-class frame to energy of signalsobtained by decoding results of encoding the low-frequency band signalsof the same-class frame, where the same-class frame is a data frame ofthe same signal class as the high-frequency band signal of the currentframe. It should be noted that, although the energy attenuation valueobtaining unit 500 and the energy attenuation value setting unit 600 aredrawn in FIG. 8, the encoding may include the energy attenuation valueobtaining unit 500 only but not include the energy attenuation valuesetting unit 600, or include the energy attenuation value setting unit600 only but not include the energy attenuation value obtaining unit 500in practical use.

The encoding device in the embodiment of the present inventionattenuates the high-frequency band signal or the characteristicparameter to be decoded of the high-frequency band signal according tothe energy attenuation value of the low-frequency band signal of thecurrent frame, and encodes and sends the attenuation result to thedecoder, so that energy of the high-frequency band signal obtained bythe decoder by decoding is attenuated accordingly. In this way, thehigh-frequency band signal is pleasant to ears of the user after beingcombined with the low-frequency band signal, thereby improving userexperience.

Referring to FIG. 9, an embodiment of the present invention provides adecoding device, which includes a decoding unit 700, configured todecode a bit stream to obtain a high-frequency band signal of a currentframe or a characteristic parameter of the high-frequency band signal ofthe current frame, and a correction unit 800, configured to attenuatethe high-frequency band signal or the characteristic parameter of thehigh-frequency band signal according to an energy attenuation value of alow-frequency band signal of the current frame, where the energyattenuation value indicates energy attenuation of the low-frequency bandsignal caused by encoding of the low-frequency band signal of thecurrent frame.

To obtain a signal class of the high-frequency band signal of thecurrent frame, the decoding unit 700 is further configured to decode thebit stream to obtain the signal class of the high-frequency band signalof the current frame, and the correction unit 800 is specificallyconfigured to attenuate the high-frequency band signal or thecharacteristic parameter of the high-frequency band signal according tothe energy attenuation value and the signal class of the high-frequencyband signal of the current frame.

Specifically, the correction unit 800 is specifically configured toattenuate a high-frequency band time-domain signal or a time-domainenvelope of the high-frequency band signal according to the energyattenuation value, when the class of the high-frequency band signal ofthe current frame is a transient class, and/or, the correction unit isspecifically configured to attenuate a high-frequency bandfrequency-domain signal or a frequency-domain envelope of thehigh-frequency band signal according to the energy attenuation value,when the class of the high-frequency band signal of the current frame isa fricative class, a harmonic class or a normal class.

To obtain the energy attenuation value of the current frame, thedecoding unit 700 is further configured to decode the energy attenuationvalue from the bit stream, where the energy attenuation value indicatesa ratio of energy of the low-frequency band signal of the current frameto energy of a signal obtained by locally decoding a result of encoding,by an encoder, the low-frequency band signal of the current frame.

Alternatively, to obtain the energy attenuation value of the currentframe, the decoding device further includes an energy attenuation valuesetting unit 900, configured to set the energy attenuation value of thecurrent frame, where the energy attenuation value is obtained accordingto a ratio of energy of a low-frequency band signal of a same-classframe to energy of a signal obtained by decoding a result of encodingthe low-frequency band signal of the same-class frame, where thesame-class frame is a data frame of the same signal class as thehigh-frequency band signal of the current frame.

The decoding device in the embodiment of the present inventionattenuates, according to the energy attenuation value of thelow-frequency band signal of the current frame, the high-frequency bandsignal or the characteristic parameter of the high-frequency band signalobtained by decoding, so that the finally obtained high-frequency bandsignal is pleasant to ears of the user after being combined with thelow-frequency band signal, thereby improving user experience.

Persons of ordinary skill in the art should understand that, all of or apart of the steps in the method according to the embodiments may beimplemented by a program instructing relevant hardware. The program maybe stored in a computer readable storage medium such as a read-onlymemory, a magnetic disk or an optical disk.

The signal classification method and device and the encoding anddecoding methods and devices according to the embodiments of the presentinvention are described in detail above. The principle andimplementation of the present invention are described herein throughspecific examples. The description about the embodiments is merelyprovided for ease of understanding of the method and core ideas of thepresent invention. Persons of ordinary skill in the art can makevariations and modifications to the present invention in terms of thespecific implementations and application scopes according to the ideasof the present invention. Therefore, the specification shall not beconstrued as a limit to the present invention.

What is claimed is:
 1. An encoding method for processing speech/audiosignals, comprising: dividing, by an encoder, a current frame into alow-frequency band signal and a high-frequency band signal, wherein theencoder comprises a processor; attenuating, by the encoder, a one of thegroup consisting of the high-frequency band signal and a to-be-encodedcharacteristic parameter of the high-frequency band signal, theattenuating being according to an energy attenuation value of thelow-frequency band signal, and wherein the energy attenuation valueindicates energy attenuation of the low-frequency band signal caused byencoding of the low-frequency band signal; and encoding, by the encoder,the one of the group consisting of the attenuated high-frequency bandsignal and the attenuated to-be-encoded characteristic parameter of thehigh-frequency band signal.
 2. The method according to claim 1, furthercomprising: determining a signal class of the high-frequency bandsignal; and wherein the attenuating the one of the group consisting ofthe high-frequency band signal and the to-be-encoded characteristicparameter of the high-frequency band signal according to the energyattenuation value of the low-frequency band signal comprises:attenuating the one of the group consisting of the high-frequency bandsignal and the to-be-encoded characteristic parameter of thehigh-frequency band signal according to the energy attenuation value andthe signal class of the high-frequency band signal.
 3. The methodaccording to claim 2, wherein the attenuating the one of the groupconsisting of the high-frequency band signal and the to-be-encodedcharacteristic parameter of the high-frequency band signal according tothe energy attenuation value and the signal class of the high-frequencyband signal comprises conditionally executing the following: when thesignal class of the high-frequency band signal is a transient class,attenuating a one of the group consisting of a high-frequency bandtime-domain signal and a to-be-encoded time domain envelope of thehigh-frequency band signal according to the energy attenuation value;and, when the signal class of the high-frequency band signal is a one ofthe group consisting of a fricative class, a harmonic class and a normalclass, attenuating one of the group consisting of a high-frequency bandfrequency-domain signal and a to-be-encoded frequency domain envelope ofthe high-frequency band signal according to the energy attenuationvalue.
 4. The method according to claim 1, further comprising: encodingthe low-frequency band signal and locally decoding a result of encodingthe low-frequency band signal; and using a ratio of energy of thelow-frequency band signal to energy of a signal obtained by the locallydecoding as the energy attenuation value.
 5. The method according toclaim 1, wherein the energy attenuation value is a preset value, and theenergy attenuation value is obtained according to ratios of energy ofmultiple low-frequency band signals of a same-class frame to energy ofsignals obtained by decoding encoding results of the low-frequency bandsignals of the same-class frame, wherein the same-class frame is a dataframe of a same signal class as the high-frequency band signal of thecurrent frame.
 6. A decoding method for processing speech/audio signals,comprising: decoding, by a decoder, a bit stream to obtain a one of thegroup consisting of (a) a high-frequency band signal of a current frameand (b) a characteristic parameter of the high-frequency band signal ofthe current frame, wherein the decoder comprises a processor; andattenuating, by the decoder, the one of the group consisting of (a) thehigh-frequency band signal and (b) the characteristic parameter of thehigh-frequency band signal according to an energy attenuation value of alow-frequency band signal of the current frame, wherein the energyattenuation value indicates energy attenuation of the low-frequency bandsignal caused by encoding of the low-frequency band signal.
 7. Themethod according to claim 6, further comprising: decoding the bit streamto obtain a signal class of the high-frequency band signal of thecurrent frame; and wherein the attenuating the one of the groupconsisting of the high-frequency band signal and the characteristicparameter of the high-frequency band signal according to the energyattenuation value of the low-frequency band signal of the current framecomprises: attenuating the one of the group consisting of thehigh-frequency band signal and the characteristic parameter of thehigh-frequency band signal according to the energy attenuation value andthe signal class of the high-frequency band signal of the current frame.8. The method according to claim 7, wherein the attenuating the one ofthe group consisting of the high-frequency band signal and thecharacteristic parameter of the high-frequency band signal according tothe energy attenuation value and the signal class of the high-frequencyband signal of the current frame comprises conditionally executing thefollowing: when the signal class of the high-frequency band signal ofthe current frame is one of the group consisting of a transient class,attenuating a high-frequency band time-domain signal and a time-domainenvelope of the high-frequency band signal according to the energyattenuation value; and when the signal class of the high-frequency bandsignal of the current frame is one of the group consisting of africative class, a harmonic class and a normal class, attenuating one ofthe group consisting of a high-frequency band frequency-domain signaland a frequency-domain envelope of the high-frequency band signalaccording to the energy attenuation value.
 9. The method according toclaim 6, further comprising: decoding the bit stream to obtain theenergy attenuation value, wherein the energy attenuation value indicatesa ratio of energy of the low-frequency band signal of the current frameto energy of a signal obtained by locally decoding a result of encoding,by an encoder, the low-frequency band signal of the current frame. 10.The method according to claim 6, wherein the energy attenuation value isa preset value, and the energy attenuation value is obtained accordingto a ratio of energy of a low-frequency band signal of a same-classframe to energy of a signal obtained by decoding a result of encodingthe low-frequency band signal of the same-class frame, wherein thesame-class frame is a data frame of a same signal class as thehigh-frequency band signal of the current frame.
 11. An encoding devicefor processing speech/audio signals, comprising: a processor; a divisionunit controlled by the processor, configured to divide a current frameinto a low-frequency band signal and a high-frequency band signal; acorrection unit controlled by the processor, configured to attenuate aone of the group consisting of the high-frequency band signal and ato-be-encoded characteristic parameter of the high-frequency band signalaccording to an energy attenuation value of the low-frequency bandsignal, wherein the energy attenuation value indicates energyattenuation of the low-frequency band signal caused by encoding of thelow-frequency band signal of the current frame; and an encoding unitcontrolled by the processor, configured to encode the one of the groupconsisting of the attenuated high-frequency band signal and theattenuated to-be-encoded characteristic parameter of the high-frequencyband signal.
 12. The device according to claim 11, further comprising: asignal class determining unit, configured to determine a signal class ofthe high-frequency band signal; wherein the correction unit isconfigured to attenuate the one of the group consisting of thehigh-frequency band signal and the to-be-encoded characteristicparameter of the high-frequency band signal according to the energyattenuation value and the signal class of the high-frequency bandsignal.
 13. The device according to claim 12, wherein the correctionunit is configured to conditionally: attenuate the one of the groupconsisting of a high-frequency band time-domain signal and ato-be-encoded time domain envelope of the high-frequency band signalaccording to the energy attenuation value when the signal class of thehigh-frequency band signal is a transient class; and attenuate the oneof the group consisting of a high-frequency band frequency-domain signaland a to-be-encoded frequency domain envelope of the high-frequency bandsignal according to the energy attenuation value when the signal classof the high-frequency band signal is one of the group consisting of africative class, a harmonic class and a normal class.
 14. The deviceaccording to claim 11, further comprises: an energy attenuation valueobtaining unit configured to encode the low-frequency band signal andlocally decode a result of encoding the low-frequency band signal, anduse a ratio of energy of the low-frequency band signal to energy of asignal obtained by the local decoding as the energy attenuation value.15. The device according to claim 11, further comprises: an energyattenuation value setting unit configured to set the energy attenuationvalue, wherein the energy attenuation value is obtained according toratios of energy of multiple low-frequency band signals of a same-classframe to energy of signals obtained by decoding results of encoding thelow-frequency band signals of the same-class frame, wherein thesame-class frame is a data frame of a same signal class as thehigh-frequency band signal of the current frame.
 16. A decoding devicefor processing speech/audio signals, comprising: a processor; a decodingunit controlled by the processor, configured to decode a bit stream toobtain a one of the group consisting of a high-frequency band signal ofa current frame and a characteristic parameter of the high-frequencyband signal of the current frame; and a correction unit controlled bythe processor, configured to attenuate the one of the group consistingof the high-frequency band signal and the characteristic parameter ofthe high-frequency band signal according to an energy attenuation valueof a low-frequency band signal of the current frame, wherein the energyattenuation value indicates energy attenuation of the low-frequency bandsignal caused by encoding of the low-frequency band signal of thecurrent frame.
 17. The device according to claim 16, wherein thedecoding unit is further configured to decode the bit stream to obtain asignal class of the high-frequency band signal of the current frame; andthe correction unit is configured to attenuate the one of the groupconsisting of the high-frequency band signal and the characteristicparameter of the high-frequency band signal according to the energyattenuation value and the signal class of the high-frequency band signalof the current frame.
 18. The device according to claim 17, wherein thecorrection unit is configured to conditionally execute the following:attenuating one of the group consisting of a high-frequency bandtime-domain signal and a time-domain envelope of the high-frequency bandsignal according to the energy attenuation value when the signal classof the high-frequency band signal of the current frame is a transientclass; and attenuating one of the group consisting of a high-frequencyband frequency-domain signal and a frequency-domain envelope of thehigh-frequency band signal according to the energy attenuation valuewhen the signal class of the high-frequency band signal of the currentframe is one of the group consisting of a fricative class, a harmonicclass and a normal class.
 19. The device according to claim 16, whereinthe decoding unit is further configured to decode the bit stream toobtain the energy attenuation value, wherein the energy attenuationvalue indicates a ratio of energy of the low-frequency band signal ofthe current frame to energy of a signal obtained by locally decoding aresult of encoding, by an encoder, the low-frequency band signal of thecurrent frame.
 20. The device according to claim 16, further comprising:an energy attenuation value setting unit configured to set the energyattenuation value of the current frame, wherein the energy attenuationvalue is obtained according to a ratio of energy of a low-frequency bandsignal of a same-class frame to energy of a signal obtained by decodinga result of encoding the low-frequency band signal of the same-classframe, and the same-class frame is a data frame of a same signal classas the high-frequency band signal of the current frame.
 21. A signalclassification method for processing speech/audio signals, comprising:dividing, by an encoder, a current frame into a low-frequency bandsignal and a high-frequency band signal, wherein the encoder comprises aprocessor; determining, by the encoder, according to a value requirementof a preset encoding/decoding characteristic parameter corresponding toa signal class, whether an encoding/decoding characteristic parameter ofthe current frame corresponding to the signal class meets the valuerequirement of the encoding/decoding characteristic parameter; anddetermining, by the encoder, a signal class of the high-frequency bandsignal of the current frame according to a determining result.
 22. Themethod according to claim 21, wherein the preset encoding/decodingcharacteristic parameter corresponding to the signal class comprises anencoding/decoding characteristic parameter corresponding to a noiseclass; and the encoding/decoding characteristic parameter correspondingto the noise class is one of the group consisting of: a correlationparameter between an amplitude of a low-frequency band frequency-domainsignal and an amplitude of a high-frequency band frequency-domainsignal, and a correlation parameter between energy of the low-frequencyband frequency-domain signal and energy of the high-frequency bandfrequency-domain signal.
 23. The method according to claim 22, furthercomprising: determining whether a number of sub-bands having apeak-to-average ratio smaller than a second threshold is greater than asecond predetermined number; and wherein the determining the signalclass of the high-frequency band signal of the current frame comprises:when the number of sub-bands having a peak-to-average ratio smaller thanthe second threshold is greater than the second predetermined number,and a value of the encoding/decoding characteristic parameter of thecurrent frame corresponding to the noise class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the noise class, determining that the signal class ofthe high-frequency band signal of the current frame is the noise class.24. The method according to claim 21, wherein the presetencoding/decoding characteristic parameter corresponding to the signalclass comprises a one of the group consisting of an encoding/decodingcharacteristic parameter corresponding to a predicted class, and anencoding/decoding characteristic parameter corresponding to a harmonicclass; and the encoding/decoding characteristic parameter correspondingto the predicted class and the encoding/decoding characteristicparameter corresponding to the harmonic class are one of the groupconsisting of: a correlation parameter between a frequency-domaincoefficient of the low-frequency band signal and a frequency-domaincoefficient of the high-frequency band signal, a correlation parameterbetween an absolute value of the frequency-domain coefficient of thelow-frequency band signal and an absolute value of the frequency-domaincoefficient of the high-frequency band signal, a correlation parameterbetween a frequency-domain coefficient of a low-frequency bandexcitation spectrum and a frequency-domain coefficient of ahigh-frequency band excitation spectrum, and a correlation parameterbetween an absolute value of the frequency-domain coefficient of thelow-frequency band excitation spectrum and an absolute value of thefrequency-domain coefficient of the high-frequency band excitationspectrum.
 25. The method according to claim 24, further comprising:determining whether a number of sub-bands having a peak-to-average ratiogreater than a first threshold is greater than a first predeterminednumber; and when the preset encoding/decoding characteristic parametercorresponding to the signal class comprises the encoding/decodingcharacteristic parameter corresponding to the harmonic class, thedetermining the signal class of the high-frequency band signal of thecurrent frame comprises: when the number of sub-bands having apeak-to-average ratio greater than the first threshold is greater thanthe first predetermined number and a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to theharmonic class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to the harmonicclass, determining that the signal class of the high-frequency bandsignal of the current frame is the harmonic class.
 26. The methodaccording to claim 24, further comprising: determining whether a numberof sub-bands having a peak-to-average ratio greater than a firstthreshold is greater than a first predetermined number; and when thepreset encoding/decoding characteristic parameter corresponding to thesignal class comprises the encoding/decoding characteristic parametercorresponding to the predicted class, the determining the signal classof the high-frequency band signal of the current frame comprises: whenthe number of sub-bands having a peak-to-average ratio greater than thefirst threshold is not greater than the first predetermined number and avalue of the encoding/decoding characteristic parameter of the currentframe corresponding to the predicted class meets the value requirementof the preset encoding/decoding characteristic parameter correspondingto the predicted class, determining that the signal class of thehigh-frequency band signal of the current frame is the predicted class.27. The method according to claim 21, wherein the presetencoding/decoding characteristic parameter corresponding to the signalclass further comprises an encoding/decoding characteristic parametercorresponding to a predicted class, and an encoding/decodingcharacteristic parameter corresponding to a harmonic class; each of theencoding/decoding characteristic parameter corresponding to thepredicted class and the encoding/decoding characteristic parametercorresponding to the harmonic class is one of the group consisting of: acorrelation parameter between a frequency-domain coefficient of thelow-frequency band signal and a frequency-domain coefficient of thehigh-frequency band signal, a correlation parameter between an absolutevalue of the frequency-domain coefficient of the low-frequency bandsignal and an absolute value of the frequency-domain coefficient of thehigh-frequency band signal, a correlation parameter between afrequency-domain coefficient of a low-frequency band excitation spectrumand a frequency-domain coefficient of a high-frequency band excitationspectrum, and a correlation parameter between an absolute value of thefrequency-domain coefficient of the low-frequency band excitationspectrum and an absolute value of the frequency-domain coefficient ofthe high-frequency band excitation spectrum; and the method furthercomprises determining whether a number of sub-bands having apeak-to-average ratio greater than a first threshold is greater than afirst predetermined number; and determining whether the number ofsub-bands having a peak-to-average ratio smaller than a second thresholdis greater than a second predetermined number; and wherein thedetermining the signal class of the high-frequency band signal of thecurrent frame comprises conditionally executing the following: when thenumber of sub-bands having a peak-to-average ratio greater than thefirst threshold is greater than the first predetermined number, and avalue of the encoding/decoding characteristic parameter of the currentframe corresponding to the harmonic class meets the value requirement ofthe preset encoding/decoding characteristic parameter corresponding tothe harmonic class, determining that the signal class of thehigh-frequency band signal of the current frame is the harmonic class;and when the number of sub-bands having a peak-to-average ratio greaterthan the first threshold is not greater than the first predeterminednumber, the number of sub-bands having a peak-to-average ratio smallerthan the second threshold is not greater than the second predeterminednumber, and a value of the encoding/decoding characteristic parameter ofthe current frame corresponding to the predicted class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the predicted class, determining that the signal classof the high-frequency band signal of the current frame is the predictedclass.
 28. The method according to claim 21, further comprising:dividing a full-frequency time-domain signal of the current frame into Nsub-frames, and when energy of one sub-frame is greater than apredetermined number of times of energy of a previous sub-frame of thesub-frame, determining that the signal class of the high-frequency bandsignal of the current frame is a transient class.
 29. A signalclassification device for processing speech/audio signals, comprising: aprocessor; a division unit controlled by the processor, configured todivide a current frame into a low-frequency band signal and ahigh-frequency band signal; a judgment unit controlled by the processor,configured to determine, according to a value requirement of a presetencoding/decoding characteristic parameter corresponding to a signalclass, whether an encoding/decoding characteristic parameter of thecurrent frame corresponding to the signal class meets the valuerequirement of the encoding/decoding characteristic parameter; and adetermination unit controlled by the processor, configured to determinea signal class of the high-frequency band signal of the current frameaccording to a determining result.
 30. The device according to claim 29,wherein the preset encoding/decoding characteristic parametercorresponding to the signal class comprises an encoding/decodingcharacteristic parameter corresponding to a noise class; and theencoding/decoding characteristic parameter corresponding to the noiseclass is one of the group consisting of: a correlation parameter betweenan amplitude of a low-frequency band frequency-domain signal and anamplitude of a high-frequency band frequency-domain signal, and acorrelation parameter between energy of the low-frequency bandfrequency-domain signal and energy of the high-frequency bandfrequency-domain signal.
 31. The device according to claim 30, whereinthe device further comprises a second peak-to-average ratio judgmentunit, configured to determine whether a number of sub-bands having apeak-to-average ratio smaller than a second threshold in thehigh-frequency band signal of the current frame is greater than a secondpredetermined number; and the determination unit comprises: a noiseclass determining unit, configured to determine that the signal class ofthe high-frequency band signal of the current frame is the noise class,when the number of sub-bands having a peak-to-average ratio smaller thanthe second threshold is greater than the second predetermined number,and a value of the encoding/decoding characteristic parameter of thecurrent frame corresponding to the noise class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the noise class.
 32. The device according to claim 29,wherein the preset encoding/decoding characteristic parametercorresponding to the signal class comprises an encoding/decodingcharacteristic parameter corresponding to a predicted class, or anencoding/decoding characteristic parameter corresponding to a harmonicclass; and each of the encoding/decoding characteristic parametercorresponding to the predicted class and the encoding/decodingcharacteristic parameter corresponding to the harmonic class is one ofthe group consisting of: a correlation parameter between afrequency-domain coefficient of the low-frequency band signal and afrequency-domain coefficient of the high-frequency band signal, acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band signal and an absolute value ofthe frequency-domain coefficient of the high-frequency band signal, acorrelation parameter between a frequency-domain coefficient of alow-frequency band excitation spectrum and a frequency-domaincoefficient of a high-frequency band excitation spectrum, and acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum and anabsolute value of the frequency-domain coefficient of the high-frequencyband excitation spectrum.
 33. The device according to claim 29, whereinthe device further comprises a first peak-to-average ratio judgmentunit, configured to determine whether a number of sub-bands having apeak-to-average ratio greater than a first threshold in thehigh-frequency band signal of the current frame is greater than a firstpredetermined number; and when the preset encoding/decodingcharacteristic parameter corresponding to the signal class comprises theencoding/decoding characteristic parameter corresponding to a harmonicclass, the determination unit comprises: a harmonic class determiningunit, configured to determine that the signal class of thehigh-frequency band signal of the current frame is the harmonic class,when the number of sub-bands having a peak-to-average ratio greater thanthe first threshold is greater than the first predetermined number, anda value of the encoding/decoding characteristic parameter of the currentframe corresponding to the harmonic class meets the value requirement ofthe preset encoding/decoding characteristic parameter corresponding tothe harmonic class.
 34. The device according to claim 29, wherein thedevice further comprises a first peak-to-average ratio judgment unit,configured to determine whether a number of sub-bands having apeak-to-average ratio greater than a first threshold in thehigh-frequency band signal of the current frame is greater than a firstpredetermined number; and when the preset encoding/decodingcharacteristic parameter corresponding to the signal class comprises theencoding/decoding characteristic parameter corresponding to a predictedclass, the determination unit comprises: a predicted class determiningunit, configured to determine that the signal class of thehigh-frequency band signal of the current frame is the predicted class,when the number of sub-bands having a peak-to-average ratio greater thanthe first threshold is not greater than the first predetermined number,and a value of the encoding/decoding characteristic parameter of thecurrent frame corresponding to the predicted class meets the valuerequirement of the preset encoding/decoding characteristic parametercorresponding to the predicted class.
 35. The device according to claim29, wherein the preset encoding/decoding characteristic parametercorresponding to the signal class comprises an encoding/decodingcharacteristic parameter corresponding to a predicted class, and anencoding/decoding characteristic parameter corresponding to a harmonicclass; each of the encoding/decoding characteristic parametercorresponding to the predicted class and the encoding/decodingcharacteristic parameter corresponding to the harmonic class is one ofthe group consisting of: a correlation parameter between afrequency-domain coefficient of the low-frequency band signal and afrequency-domain coefficient of the high-frequency band signal, acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band signal and an absolute value ofthe frequency-domain coefficient of the high-frequency band signal, acorrelation parameter between a frequency-domain coefficient of alow-frequency band excitation spectrum and a frequency-domaincoefficient of a high-frequency band excitation spectrum, and acorrelation parameter between an absolute value of the frequency-domaincoefficient of the low-frequency band excitation spectrum and anabsolute value of the frequency-domain coefficient of the high-frequencyband excitation spectrum; the device further comprises a firstpeak-to-average ratio judgment unit, configured to determine whether anumber of sub-bands having a peak-to-average ratio greater than a firstthreshold in the high-frequency band signal of the current frame isgreater than a first predetermined number; and a second peak-to-averageratio judgment unit, configured to determine whether the number ofsub-bands having a peak-to-average ratio smaller than a second thresholdin the high-frequency band signal of the current frame is greater than asecond predetermined number; and the determination unit comprises: aharmonic class determining unit, configured to determine that the signalclass of the high-frequency band signal of the current frame is theharmonic class, when the number of sub-bands having a peak-to-averageratio greater than the first threshold is greater than the firstpredetermined number, and a value of the encoding/decodingcharacteristic parameter of the current frame corresponding to theharmonic class meets the value requirement of the presetencoding/decoding characteristic parameter corresponding to the harmonicclass; and a predicted class determining unit, configured to determinethat the signal class of the high-frequency band signal of the currentframe is the predicted class, when the number of sub-bands having apeak-to-average ratio greater than the first threshold is greater thanthe first predetermined number, the number of sub-bands having apeak-to-average ratio smaller than the second threshold is not greaterthan the second predetermined number, and a value of theencoding/decoding characteristic parameter of the current framecorresponding to the predicted class meets the value requirement of thepreset encoding/decoding characteristic parameter corresponding to thepredicted class.
 36. The device according to claim 29, wherein thedevice further comprises: a transient class determining unit, configuredto divide a full-frequency band time-domain signal of the current frameinto N sub-frames, and when energy of one sub-frame is greater than apredetermined number of times of energy of a previous sub-frame of thesub-frame, determine that the signal class of the high-frequency bandsignal of the current frame is a transient class.